package vtc;

import java.util.concurrent.*;
import java.io.*;

// One single input queue and one single output queue

abstract class OutputUnit extends VtcUnit 
{
	protected VtcTimeTaggedEvent inValue_;
	
	OutputUnit(String id, VtcArrayBlockingQueue inQueues[]) 
	{
		//dummy output queue
		super(id, inQueues, null);
	}
	
	abstract public void outputProcess() throws InterruptedException;
		
	public void process() throws InterruptedException
	{
		inValue_ = inQueues_[0].take();
		//System.out.print("qq\n");
		this.outputProcess();
	}
}